Scroll to navigation

sesearch(1) SETools: SELinux Policy Analysis Tools sesearch(1)

NAME

sesearch - SELinux policy query tool

SYNOPSIS

sesearch [OPTIONS] [OPTIONS] [EXPRESSION] [POLICY]

DESCRIPTION

sesearch allows the user to search the rules in a SELinux policy.

POLICY

A single file containing a binary policy. This file is usually named by version on Linux systems, for example, policy.30. This file is usually named sepolicy on Android systems. If no policy file is provided, sesearch will search for the policy running on the current system. If no policy can be found, sesearch will print an error message and exit.

EXPRESSIONS

The user may specify an expression containing values for a given field(s) in a rule. If no expression is specified or if none of the specified fields apply to a given rule type, all rules of that type are considered to match the expression.

Type Enforcement Rule Types

Find allow and allowxperm rules.
Find allow rules.
Find auditallow rules.
Find dontaudit rules.
Find allowxperm rules.
Find auditallowxperm rules.
Find dontauditxperm rules.
Find type_transition rules.
Find type_member rules.
Find type_change rules.

RBAC Rule Types

Find role allow rules.
Find role_transition rules.

MLS Rule Types

Find range_transition rules.

Rule Fields

Find rules with NAME as their source type/role.
Find rules with NAME as their target type/role.
Find rules with NAME as their default type/role/level.
Find rules with NAME as their object class.
Find rules with at least one of the specified permissions. Multiple permissions may be specified as a comma-separated list.
Find conditional rules with the named Boolean in their conditional expression. Multiple Booleans may be specified as a comma-separated list. This option will include rules in both the true and false lists of the conditional.

Search Options

The following additional options modify how the search is performed.

A matching rule must have the specified source attribute/type/role explicitly, instead of matching by attribute contents.
A matching rule must have the specified target attribute/type/role explicitly, instead of matching by attribute contents.
A matching rule must have all specified Booleans, instead of matching any of the specified Boolean.
A matching rule must have all specified permissions, instead of matching any of the specified permission.
Use regular expression for matching the source type/role.
Use regular expression for matching the target type/role.
Use regular expression for matching the object class.
Use regular expression for matching the default type/role.
Use regular expression for matching Booleans.

OPTIONS

Print help information and exit.
Print version information and exit.
Print additional informational messages.
Enable debugging output.

AUTHOR

Chris PeBenito <pebenito@ieee.org>

BUGS

Please report bugs via the SETools bug tracker, https://github.com/SELinuxProject/setools/issues

SEE ALSO

apol(1), sediff(1), sedta(1), seinfo(1), seinfoflow(1)

2016-02-20 SELinux Project